/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package GUI;

import DAO.Fechas;
import DTO.garantiaHipotecariaDTO;
import DAO.garantiasDAO;
import DTO.ComprobanteGeneralDTO;
import DTO.usuarioDTO;
import java.awt.Desktop;
import java.io.File;
import java.io.IOException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.JFileChooser;
import javax.swing.JFrame;
import javax.swing.JOptionPane;
import javax.swing.table.DefaultTableModel;
import net.sf.jasperreports.engine.JRException;
import net.sf.jasperreports.engine.JasperCompileManager;
import net.sf.jasperreports.engine.JasperFillManager;
import net.sf.jasperreports.engine.JasperPrint;
import net.sf.jasperreports.engine.JasperReport;
import net.sf.jasperreports.engine.data.JRBeanCollectionDataSource;
import net.sf.jasperreports.swing.JRViewer;
/**
 *
 * @author Luis Olave 10
 */
public class EliminacionGarantiaHipotecaria extends javax.swing.JFrame {
    usuarioDTO user;
    garantiasDAO reg = new garantiasDAO();
    garantiaHipotecariaDTO garantia;
    String fec = "";
    public EliminacionGarantiaHipotecaria(usuarioDTO user) {
        this.user = user;
        initComponents();
        chkBuscarPorFolio.setSelected(true);
        pnlRolGarantia.setVisible(false);
        this.btnEliminarGarantiaHipo.setVisible(false);
        this.setDefaultCloseOperation(this.EXIT_ON_CLOSE);
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        buttonGroup1 = new javax.swing.ButtonGroup();
        jLabel2 = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        jTabbedPane1 = new javax.swing.JTabbedPane();
        jPanel1 = new javax.swing.JPanel();
        btnVolverMenuPrincipal = new javax.swing.JButton();
        pnlDatosPersoGara = new javax.swing.JPanel();
        jPanel10 = new javax.swing.JPanel();
        jLabel36 = new javax.swing.JLabel();
        jLabel37 = new javax.swing.JLabel();
        jLabel39 = new javax.swing.JLabel();
        jLabel40 = new javax.swing.JLabel();
        txtNombre = new javax.swing.JTextField();
        txtApellMaterno = new javax.swing.JTextField();
        txtApellPaterno = new javax.swing.JTextField();
        txtRut = new javax.swing.JTextField();
        chkBuscarPorFolio = new javax.swing.JCheckBox();
        chkBuscarPorRol = new javax.swing.JCheckBox();
        pnlRolGarantia = new javax.swing.JPanel();
        jLabel30 = new javax.swing.JLabel();
        txtRolBuscar = new javax.swing.JTextField();
        btnBuscarPorRol = new javax.swing.JButton();
        pnlFolioGarantia = new javax.swing.JPanel();
        jLabel31 = new javax.swing.JLabel();
        txtNumFolioBuscar = new javax.swing.JTextField();
        btnBuscarPorFolio = new javax.swing.JButton();
        jPanel2 = new javax.swing.JPanel();
        pnlDescripGarantia = new javax.swing.JPanel();
        jScrollPane4 = new javax.swing.JScrollPane();
        txtDescripcion = new javax.swing.JTextArea();
        lblDescripcion = new javax.swing.JLabel();
        jPanel3 = new javax.swing.JPanel();
        pnlCreacionGaraHipo = new javax.swing.JPanel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jPanel4 = new javax.swing.JPanel();
        jPanel5 = new javax.swing.JPanel();
        jLabel14 = new javax.swing.JLabel();
        jLabel15 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        jLabel17 = new javax.swing.JLabel();
        jLabel18 = new javax.swing.JLabel();
        jLabel19 = new javax.swing.JLabel();
        jLabel20 = new javax.swing.JLabel();
        jLabel21 = new javax.swing.JLabel();
        txtGradoPreferencia = new javax.swing.JTextField();
        txtFechUltReval = new javax.swing.JTextField();
        txtFechUtlCredito = new javax.swing.JTextField();
        txtExtincion = new javax.swing.JTextField();
        txtFojas = new javax.swing.JTextField();
        txtAñosRepertorio = new javax.swing.JTextField();
        txtMtsConstruidos = new javax.swing.JTextField();
        txtTipoGarantia = new javax.swing.JTextField();
        jLabel63 = new javax.swing.JLabel();
        txtFechModifi = new javax.swing.JTextField();
        jPanel11 = new javax.swing.JPanel();
        jLabel54 = new javax.swing.JLabel();
        jLabel55 = new javax.swing.JLabel();
        jLabel56 = new javax.swing.JLabel();
        jLabel57 = new javax.swing.JLabel();
        jLabel58 = new javax.swing.JLabel();
        jLabel59 = new javax.swing.JLabel();
        jLabel60 = new javax.swing.JLabel();
        jLabel61 = new javax.swing.JLabel();
        jLabel62 = new javax.swing.JLabel();
        jLabel64 = new javax.swing.JLabel();
        jLabel65 = new javax.swing.JLabel();
        jLabel66 = new javax.swing.JLabel();
        jLabel67 = new javax.swing.JLabel();
        jLabel68 = new javax.swing.JLabel();
        jLabel69 = new javax.swing.JLabel();
        jLabel70 = new javax.swing.JLabel();
        txtDireccion = new javax.swing.JTextField();
        txtLocalidadRegistro = new javax.swing.JTextField();
        txtEstadoContribu = new javax.swing.JTextField();
        txtFechUltTasacion = new javax.swing.JTextField();
        txtNumero = new javax.swing.JTextField();
        txtRegistroCbr = new javax.swing.JTextField();
        txtRolSii = new javax.swing.JTextField();
        txtUniSuperficie = new javax.swing.JTextField();
        txtTipoConstruccion = new javax.swing.JTextField();
        txtComuna = new javax.swing.JTextField();
        txtMoneda = new javax.swing.JTextField();
        txtFechUltDebito = new javax.swing.JTextField();
        txtFechCreacion = new javax.swing.JTextField();
        txtSuperficie = new javax.swing.JTextField();
        txtCobertura = new javax.swing.JTextField();
        txtSucursal = new javax.swing.JTextField();
        jPanel14 = new javax.swing.JPanel();
        lblArchivo = new javax.swing.JLabel();
        btnExaminar = new javax.swing.JButton();
        jButton10 = new javax.swing.JButton();
        btnEliminarGarantiaHipo = new javax.swing.JButton();
        jPanel9 = new javax.swing.JPanel();
        txtEstadoActualHipotecaria = new javax.swing.JTextField();
        jPanelCambiandoEstadoActual = new javax.swing.JPanel();
        txtCambiandoEstadoActualHipotecaria = new javax.swing.JTextField();
        jPanel6 = new javax.swing.JPanel();
        jPanel7 = new javax.swing.JPanel();
        jScrollPane2 = new javax.swing.JScrollPane();
        tbSalidaRolImprmir = new javax.swing.JTable();
        jPanel8 = new javax.swing.JPanel();
        txtBuscarRolImprimir = new javax.swing.JTextField();
        btnBuscarRolImprimir = new javax.swing.JButton();
        btnImprimirRol = new javax.swing.JButton();
        btnMenuPrincipalHipo = new javax.swing.JButton();
        jLabel3 = new javax.swing.JLabel();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("ELIMINACIÓN GARANTÍA HIPOTECARIA");
        setResizable(false);

        jLabel2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/IMAGE/logo.JPG"))); // NOI18N

        jLabel1.setFont(new java.awt.Font("Century Gothic", 1, 18)); // NOI18N
        jLabel1.setText("ELIMINACIÓN GARANTÍA HIPOTECARIA");

        jTabbedPane1.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N

        btnVolverMenuPrincipal.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        btnVolverMenuPrincipal.setText("MENÚ PRINCIPAL");
        btnVolverMenuPrincipal.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnVolverMenuPrincipalActionPerformed(evt);
            }
        });

        pnlDatosPersoGara.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "DATOS PERSONALES GARANTE", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        jLabel36.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel36.setText("RUT");

        jLabel37.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel37.setText("APELLIDO PATERNO");

        jLabel39.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel39.setText("APELLIDO MATERNO");

        jLabel40.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel40.setText("NOMBRE");

        txtNombre.setBackground(new java.awt.Color(255, 255, 102));
        txtNombre.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtNombre.setEnabled(false);

        txtApellMaterno.setBackground(new java.awt.Color(255, 255, 102));
        txtApellMaterno.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtApellMaterno.setEnabled(false);

        txtApellPaterno.setBackground(new java.awt.Color(255, 255, 102));
        txtApellPaterno.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtApellPaterno.setEnabled(false);

        txtRut.setBackground(new java.awt.Color(255, 255, 102));
        txtRut.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtRut.setEnabled(false);

        javax.swing.GroupLayout jPanel10Layout = new javax.swing.GroupLayout(jPanel10);
        jPanel10.setLayout(jPanel10Layout);
        jPanel10Layout.setHorizontalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel10Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel37)
                    .addComponent(jLabel36))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(txtRut, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(txtApellPaterno, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 75, Short.MAX_VALUE)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addGroup(jPanel10Layout.createSequentialGroup()
                        .addComponent(jLabel39)
                        .addGap(18, 18, 18)
                        .addComponent(txtApellMaterno, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanel10Layout.createSequentialGroup()
                        .addComponent(jLabel40)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(txtNombre, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(196, 196, 196))
        );
        jPanel10Layout.setVerticalGroup(
            jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel10Layout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel36)
                    .addComponent(txtRut, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel40)
                    .addComponent(txtNombre, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(jPanel10Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel37)
                    .addComponent(txtApellPaterno, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel39)
                    .addComponent(txtApellMaterno, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );

        javax.swing.GroupLayout pnlDatosPersoGaraLayout = new javax.swing.GroupLayout(pnlDatosPersoGara);
        pnlDatosPersoGara.setLayout(pnlDatosPersoGaraLayout);
        pnlDatosPersoGaraLayout.setHorizontalGroup(
            pnlDatosPersoGaraLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlDatosPersoGaraLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel10, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        pnlDatosPersoGaraLayout.setVerticalGroup(
            pnlDatosPersoGaraLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlDatosPersoGaraLayout.createSequentialGroup()
                .addGap(0, 0, Short.MAX_VALUE)
                .addComponent(jPanel10, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
        );

        buttonGroup1.add(chkBuscarPorFolio);
        chkBuscarPorFolio.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        chkBuscarPorFolio.setText("BUSCAR POR N° FOLIO");
        chkBuscarPorFolio.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                chkBuscarPorFolioActionPerformed(evt);
            }
        });

        buttonGroup1.add(chkBuscarPorRol);
        chkBuscarPorRol.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        chkBuscarPorRol.setText("BUSCAR POR ROL SII");
        chkBuscarPorRol.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                chkBuscarPorRolActionPerformed(evt);
            }
        });

        pnlRolGarantia.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "INGRESE ROL SII", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        jLabel30.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel30.setText("ROL");

        btnBuscarPorRol.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        btnBuscarPorRol.setText("BUSCAR");
        btnBuscarPorRol.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBuscarPorRolActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout pnlRolGarantiaLayout = new javax.swing.GroupLayout(pnlRolGarantia);
        pnlRolGarantia.setLayout(pnlRolGarantiaLayout);
        pnlRolGarantiaLayout.setHorizontalGroup(
            pnlRolGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlRolGarantiaLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel30)
                .addGap(18, 18, 18)
                .addGroup(pnlRolGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(txtRolBuscar)
                    .addComponent(btnBuscarPorRol, javax.swing.GroupLayout.DEFAULT_SIZE, 100, Short.MAX_VALUE))
                .addContainerGap(52, Short.MAX_VALUE))
        );
        pnlRolGarantiaLayout.setVerticalGroup(
            pnlRolGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlRolGarantiaLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(pnlRolGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel30)
                    .addComponent(txtRolBuscar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(btnBuscarPorRol)
                .addContainerGap())
        );

        pnlFolioGarantia.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "INGRESE N° FOLIO", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        jLabel31.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel31.setText("N° FOLIO");

        btnBuscarPorFolio.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        btnBuscarPorFolio.setText("BUSCAR");
        btnBuscarPorFolio.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBuscarPorFolioActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout pnlFolioGarantiaLayout = new javax.swing.GroupLayout(pnlFolioGarantia);
        pnlFolioGarantia.setLayout(pnlFolioGarantiaLayout);
        pnlFolioGarantiaLayout.setHorizontalGroup(
            pnlFolioGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlFolioGarantiaLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel31)
                .addGap(18, 18, 18)
                .addGroup(pnlFolioGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(txtNumFolioBuscar)
                    .addComponent(btnBuscarPorFolio, javax.swing.GroupLayout.DEFAULT_SIZE, 100, Short.MAX_VALUE))
                .addContainerGap(52, Short.MAX_VALUE))
        );
        pnlFolioGarantiaLayout.setVerticalGroup(
            pnlFolioGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlFolioGarantiaLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(pnlFolioGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel31)
                    .addComponent(txtNumFolioBuscar, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(btnBuscarPorFolio)
                .addContainerGap())
        );

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(pnlDatosPersoGara, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addContainerGap())
                    .addGroup(jPanel1Layout.createSequentialGroup()
                        .addComponent(btnVolverMenuPrincipal, javax.swing.GroupLayout.PREFERRED_SIZE, 147, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel1Layout.createSequentialGroup()
                        .addGap(0, 168, Short.MAX_VALUE)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(pnlFolioGarantia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(chkBuscarPorFolio))
                        .addGap(18, 18, 18)
                        .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                            .addComponent(chkBuscarPorRol)
                            .addComponent(pnlRolGarantia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(140, 140, 140))))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(chkBuscarPorFolio, javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(chkBuscarPorRol, javax.swing.GroupLayout.Alignment.TRAILING))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(pnlRolGarantia, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(pnlFolioGarantia, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addComponent(pnlDatosPersoGara, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(120, 120, 120)
                .addComponent(btnVolverMenuPrincipal)
                .addContainerGap(94, Short.MAX_VALUE))
        );

        jTabbedPane1.addTab("INFO. GARANTE", jPanel1);

        pnlDescripGarantia.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "DESCRIPCIÓN GARANTIA", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        txtDescripcion.setBackground(new java.awt.Color(255, 255, 102));
        txtDescripcion.setColumns(20);
        txtDescripcion.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        txtDescripcion.setRows(5);
        txtDescripcion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtDescripcion.setEnabled(false);
        jScrollPane4.setViewportView(txtDescripcion);

        lblDescripcion.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        lblDescripcion.setText("DESCRIPCIÓN");

        javax.swing.GroupLayout pnlDescripGarantiaLayout = new javax.swing.GroupLayout(pnlDescripGarantia);
        pnlDescripGarantia.setLayout(pnlDescripGarantiaLayout);
        pnlDescripGarantiaLayout.setHorizontalGroup(
            pnlDescripGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlDescripGarantiaLayout.createSequentialGroup()
                .addGap(70, 70, 70)
                .addComponent(lblDescripcion)
                .addGap(18, 18, 18)
                .addComponent(jScrollPane4, javax.swing.GroupLayout.DEFAULT_SIZE, 586, Short.MAX_VALUE)
                .addContainerGap())
        );
        pnlDescripGarantiaLayout.setVerticalGroup(
            pnlDescripGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlDescripGarantiaLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(pnlDescripGarantiaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblDescripcion)
                    .addComponent(jScrollPane4, javax.swing.GroupLayout.PREFERRED_SIZE, 89, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(367, 367, 367))
        );

        javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
        jPanel2.setLayout(jPanel2Layout);
        jPanel2Layout.setHorizontalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(pnlDescripGarantia, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );
        jPanel2Layout.setVerticalGroup(
            jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(pnlDescripGarantia, javax.swing.GroupLayout.PREFERRED_SIZE, 359, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(120, Short.MAX_VALUE))
        );

        jTabbedPane1.addTab("DESCRIP. GARANTÍA", jPanel2);

        pnlCreacionGaraHipo.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "ELIMINACIÓN GARANTÍA HIPOTECARIA", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N
        pnlCreacionGaraHipo.setPreferredSize(new java.awt.Dimension(692, 600));

        jPanel4.setPreferredSize(new java.awt.Dimension(740, 470));

        jLabel14.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel14.setText("TIPO GARANTÍA");

        jLabel15.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel15.setText("GRADO PREFERENCÍA");

        jLabel16.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel16.setText("MTS. CONSTRUIDOS");

        jLabel17.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel17.setText("AÑOS REPERTORIO");

        jLabel18.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel18.setText("A. FOJAS");

        jLabel19.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel19.setText("FECHA EXTINCIÓN");

        jLabel20.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel20.setText("FECHA ÚLT. REVALUO");

        jLabel21.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel21.setText("FECHA ÚLT. CRÉDITO");

        txtGradoPreferencia.setBackground(new java.awt.Color(255, 255, 102));
        txtGradoPreferencia.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtGradoPreferencia.setEnabled(false);

        txtFechUltReval.setBackground(new java.awt.Color(255, 255, 102));
        txtFechUltReval.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechUltReval.setEnabled(false);

        txtFechUtlCredito.setBackground(new java.awt.Color(255, 255, 102));
        txtFechUtlCredito.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechUtlCredito.setEnabled(false);

        txtExtincion.setBackground(new java.awt.Color(255, 255, 102));
        txtExtincion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtExtincion.setEnabled(false);

        txtFojas.setBackground(new java.awt.Color(255, 255, 102));
        txtFojas.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFojas.setEnabled(false);

        txtAñosRepertorio.setBackground(new java.awt.Color(255, 255, 102));
        txtAñosRepertorio.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtAñosRepertorio.setEnabled(false);

        txtMtsConstruidos.setBackground(new java.awt.Color(255, 255, 102));
        txtMtsConstruidos.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtMtsConstruidos.setEnabled(false);

        txtTipoGarantia.setBackground(new java.awt.Color(255, 255, 102));
        txtTipoGarantia.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtTipoGarantia.setEnabled(false);

        jLabel63.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel63.setText("FECHA MODIFICA.");

        txtFechModifi.setBackground(new java.awt.Color(255, 255, 102));
        txtFechModifi.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechModifi.setEnabled(false);

        javax.swing.GroupLayout jPanel5Layout = new javax.swing.GroupLayout(jPanel5);
        jPanel5.setLayout(jPanel5Layout);
        jPanel5Layout.setHorizontalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel5Layout.createSequentialGroup()
                        .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel15)
                            .addComponent(jLabel20)
                            .addComponent(jLabel21)
                            .addComponent(jLabel19)
                            .addComponent(jLabel18)
                            .addComponent(jLabel17)
                            .addComponent(jLabel16)
                            .addComponent(jLabel14))
                        .addGap(18, 18, 18)
                        .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtTipoGarantia, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtMtsConstruidos, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtAñosRepertorio, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFojas, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtExtincion, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFechUtlCredito, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFechUltReval, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtGradoPreferencia, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(0, 0, Short.MAX_VALUE))
                    .addGroup(jPanel5Layout.createSequentialGroup()
                        .addComponent(jLabel63)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(txtFechModifi, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel5Layout.setVerticalGroup(
            jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel5Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel14)
                    .addComponent(txtTipoGarantia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel15)
                    .addComponent(txtGradoPreferencia, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel16)
                    .addComponent(txtMtsConstruidos, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel17)
                    .addComponent(txtAñosRepertorio, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel18)
                    .addComponent(txtFojas, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel19)
                    .addComponent(txtExtincion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel20)
                    .addComponent(txtFechUltReval, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel21)
                    .addComponent(txtFechUtlCredito, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel5Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtFechModifi, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel63))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jLabel54.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel54.setText("SUCURSAL");

        jLabel55.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel55.setText("COBERTURA");

        jLabel56.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel56.setText("SUPERFICIE");

        jLabel57.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel57.setText("DIRECCIÓN (CRÉDITO)");

        jLabel58.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel58.setText("REGISTRO CBR");

        jLabel59.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel59.setText("ROL SII");

        jLabel60.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel60.setText("UNIDAD SUPERFICIE");

        jLabel61.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel61.setText("FECHA CREACIÓN");

        jLabel62.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel62.setText("FECHA ÚLT. DÉBITO");

        jLabel64.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel64.setText("FECHA ÚLT. TASACIÓN");

        jLabel65.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel65.setText("NÚMERO");

        jLabel66.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel66.setText("LOCALIDAD REGISTRO");

        jLabel67.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel67.setText("ESTADO CONTRIB.");

        jLabel68.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel68.setText("COMUNA");

        jLabel69.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel69.setText("TIPO CONSTRUCCIÓN");

        jLabel70.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jLabel70.setText("MONEDA");

        txtDireccion.setBackground(new java.awt.Color(255, 255, 102));
        txtDireccion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtDireccion.setEnabled(false);

        txtLocalidadRegistro.setBackground(new java.awt.Color(255, 255, 102));
        txtLocalidadRegistro.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtLocalidadRegistro.setEnabled(false);

        txtEstadoContribu.setBackground(new java.awt.Color(255, 255, 102));
        txtEstadoContribu.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtEstadoContribu.setEnabled(false);

        txtFechUltTasacion.setBackground(new java.awt.Color(255, 255, 102));
        txtFechUltTasacion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechUltTasacion.setEnabled(false);

        txtNumero.setBackground(new java.awt.Color(255, 255, 102));
        txtNumero.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtNumero.setEnabled(false);

        txtRegistroCbr.setBackground(new java.awt.Color(255, 255, 102));
        txtRegistroCbr.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtRegistroCbr.setEnabled(false);

        txtRolSii.setBackground(new java.awt.Color(255, 255, 102));
        txtRolSii.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtRolSii.setEnabled(false);

        txtUniSuperficie.setBackground(new java.awt.Color(255, 255, 102));
        txtUniSuperficie.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtUniSuperficie.setEnabled(false);

        txtTipoConstruccion.setBackground(new java.awt.Color(255, 255, 102));
        txtTipoConstruccion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtTipoConstruccion.setEnabled(false);

        txtComuna.setBackground(new java.awt.Color(255, 255, 102));
        txtComuna.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtComuna.setEnabled(false);

        txtMoneda.setBackground(new java.awt.Color(255, 255, 102));
        txtMoneda.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtMoneda.setEnabled(false);

        txtFechUltDebito.setBackground(new java.awt.Color(255, 255, 102));
        txtFechUltDebito.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechUltDebito.setEnabled(false);

        txtFechCreacion.setBackground(new java.awt.Color(255, 255, 102));
        txtFechCreacion.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtFechCreacion.setEnabled(false);

        txtSuperficie.setBackground(new java.awt.Color(255, 255, 102));
        txtSuperficie.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtSuperficie.setEnabled(false);

        txtCobertura.setBackground(new java.awt.Color(255, 255, 102));
        txtCobertura.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtCobertura.setEnabled(false);

        txtSucursal.setBackground(new java.awt.Color(255, 255, 102));
        txtSucursal.setDisabledTextColor(new java.awt.Color(0, 0, 204));
        txtSucursal.setEnabled(false);

        javax.swing.GroupLayout jPanel11Layout = new javax.swing.GroupLayout(jPanel11);
        jPanel11.setLayout(jPanel11Layout);
        jPanel11Layout.setHorizontalGroup(
            jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel11Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(jPanel11Layout.createSequentialGroup()
                        .addComponent(jLabel57)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(txtDireccion, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jPanel11Layout.createSequentialGroup()
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel62)
                            .addComponent(jLabel61)
                            .addComponent(jLabel54)
                            .addComponent(jLabel55)
                            .addComponent(jLabel56)
                            .addComponent(jLabel58)
                            .addComponent(jLabel59)
                            .addComponent(jLabel60)
                            .addComponent(jLabel70))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtCobertura, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtSucursal, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtSuperficie, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanel11Layout.createSequentialGroup()
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel69)
                            .addComponent(jLabel68)
                            .addComponent(jLabel67)
                            .addComponent(jLabel66)
                            .addComponent(jLabel65)
                            .addComponent(jLabel64))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 24, Short.MAX_VALUE)
                        .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtRegistroCbr, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtRolSii, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtUniSuperficie, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtEstadoContribu, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtLocalidadRegistro, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtNumero, javax.swing.GroupLayout.PREFERRED_SIZE, 80, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFechUltTasacion, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtTipoConstruccion, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtComuna, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtMoneda, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFechUltDebito, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(txtFechCreacion, javax.swing.GroupLayout.PREFERRED_SIZE, 158, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel11Layout.setVerticalGroup(
            jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel11Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel54)
                    .addComponent(txtSucursal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel55)
                    .addComponent(txtCobertura, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel56)
                    .addComponent(txtSuperficie, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel57)
                    .addComponent(txtDireccion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel58)
                    .addComponent(txtRegistroCbr, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel59)
                    .addComponent(txtRolSii, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel60)
                    .addComponent(txtUniSuperficie, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel61)
                    .addComponent(txtFechCreacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel62)
                    .addComponent(txtFechUltDebito, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel70)
                    .addComponent(txtMoneda, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel69)
                    .addComponent(txtTipoConstruccion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel68)
                    .addComponent(txtComuna, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel67)
                    .addComponent(txtEstadoContribu, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel66)
                    .addComponent(txtLocalidadRegistro, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel65)
                    .addComponent(txtNumero, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(jPanel11Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel64)
                    .addComponent(txtFechUltTasacion, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        jPanel14.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "ADJUNTAR ARCHIVO", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        lblArchivo.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        lblArchivo.setText("VER");

        btnExaminar.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        btnExaminar.setText("VER ARCHIVO");
        btnExaminar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnExaminarActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel14Layout = new javax.swing.GroupLayout(jPanel14);
        jPanel14.setLayout(jPanel14Layout);
        jPanel14Layout.setHorizontalGroup(
            jPanel14Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel14Layout.createSequentialGroup()
                .addGap(67, 67, 67)
                .addComponent(lblArchivo)
                .addGap(18, 18, 18)
                .addComponent(btnExaminar)
                .addContainerGap(90, Short.MAX_VALUE))
        );
        jPanel14Layout.setVerticalGroup(
            jPanel14Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel14Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel14Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblArchivo)
                    .addComponent(btnExaminar))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout jPanel4Layout = new javax.swing.GroupLayout(jPanel4);
        jPanel4.setLayout(jPanel4Layout);
        jPanel4Layout.setHorizontalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel11, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(68, 68, 68)
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(0, 3, Short.MAX_VALUE))
                    .addComponent(jPanel14, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        jPanel4Layout.setVerticalGroup(
            jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel4Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanel4Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jPanel11, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addGroup(jPanel4Layout.createSequentialGroup()
                        .addComponent(jPanel5, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jPanel14, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap(27, Short.MAX_VALUE))
        );

        jScrollPane1.setViewportView(jPanel4);

        javax.swing.GroupLayout pnlCreacionGaraHipoLayout = new javax.swing.GroupLayout(pnlCreacionGaraHipo);
        pnlCreacionGaraHipo.setLayout(pnlCreacionGaraHipoLayout);
        pnlCreacionGaraHipoLayout.setHorizontalGroup(
            pnlCreacionGaraHipoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 759, javax.swing.GroupLayout.PREFERRED_SIZE)
        );
        pnlCreacionGaraHipoLayout.setVerticalGroup(
            pnlCreacionGaraHipoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 364, Short.MAX_VALUE)
        );

        jButton10.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        jButton10.setText("MENÚ PRINCIPAL >>");
        jButton10.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton10ActionPerformed(evt);
            }
        });

        btnEliminarGarantiaHipo.setFont(new java.awt.Font("Century Gothic", 0, 12)); // NOI18N
        btnEliminarGarantiaHipo.setText("ELIMINAR");
        btnEliminarGarantiaHipo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnEliminarGarantiaHipoActionPerformed(evt);
            }
        });

        jPanel9.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "ESTADO ACTUAL", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        txtEstadoActualHipotecaria.setEditable(false);

        javax.swing.GroupLayout jPanel9Layout = new javax.swing.GroupLayout(jPanel9);
        jPanel9.setLayout(jPanel9Layout);
        jPanel9Layout.setHorizontalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel9Layout.createSequentialGroup()
                .addGap(38, 38, 38)
                .addComponent(txtEstadoActualHipotecaria, javax.swing.GroupLayout.PREFERRED_SIZE, 74, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(38, Short.MAX_VALUE))
        );
        jPanel9Layout.setVerticalGroup(
            jPanel9Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(txtEstadoActualHipotecaria, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
        );

        jPanelCambiandoEstadoActual.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "CAMBIANDO ESTADO ACTUAL", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        txtCambiandoEstadoActualHipotecaria.setEditable(false);
        txtCambiandoEstadoActualHipotecaria.setText("Eliminando");

        javax.swing.GroupLayout jPanelCambiandoEstadoActualLayout = new javax.swing.GroupLayout(jPanelCambiandoEstadoActual);
        jPanelCambiandoEstadoActual.setLayout(jPanelCambiandoEstadoActualLayout);
        jPanelCambiandoEstadoActualLayout.setHorizontalGroup(
            jPanelCambiandoEstadoActualLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelCambiandoEstadoActualLayout.createSequentialGroup()
                .addGap(38, 38, 38)
                .addComponent(txtCambiandoEstadoActualHipotecaria, javax.swing.GroupLayout.PREFERRED_SIZE, 74, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(38, Short.MAX_VALUE))
        );
        jPanelCambiandoEstadoActualLayout.setVerticalGroup(
            jPanelCambiandoEstadoActualLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(txtCambiandoEstadoActualHipotecaria, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
        );

        javax.swing.GroupLayout jPanel3Layout = new javax.swing.GroupLayout(jPanel3);
        jPanel3.setLayout(jPanel3Layout);
        jPanel3Layout.setHorizontalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(pnlCreacionGaraHipo, javax.swing.GroupLayout.DEFAULT_SIZE, 775, Short.MAX_VALUE)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel3Layout.createSequentialGroup()
                                .addGap(0, 0, Short.MAX_VALUE)
                                .addComponent(jPanel9, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(39, 39, 39)
                                .addComponent(jPanelCambiandoEstadoActual, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addGroup(jPanel3Layout.createSequentialGroup()
                        .addGap(353, 353, 353)
                        .addComponent(btnEliminarGarantiaHipo)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(jButton10, javax.swing.GroupLayout.PREFERRED_SIZE, 165, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );
        jPanel3Layout.setVerticalGroup(
            jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel3Layout.createSequentialGroup()
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(jPanelCambiandoEstadoActual, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jPanel9, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(pnlCreacionGaraHipo, javax.swing.GroupLayout.DEFAULT_SIZE, 387, Short.MAX_VALUE)
                .addGap(18, 18, 18)
                .addGroup(jPanel3Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnEliminarGarantiaHipo)
                    .addComponent(jButton10))
                .addContainerGap())
        );

        jTabbedPane1.addTab("ELIMINACIÓN GARANTÍA HIPOTECARIA", jPanel3);

        jPanel7.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "ÁREA IMPRESIÓN", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        tbSalidaRolImprmir.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {

            }
        ));
        tbSalidaRolImprmir.setEnabled(false);
        jScrollPane2.setViewportView(tbSalidaRolImprmir);

        javax.swing.GroupLayout jPanel7Layout = new javax.swing.GroupLayout(jPanel7);
        jPanel7.setLayout(jPanel7Layout);
        jPanel7Layout.setHorizontalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane2)
                .addContainerGap())
        );
        jPanel7Layout.setVerticalGroup(
            jPanel7Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel7Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 276, Short.MAX_VALUE)
                .addContainerGap())
        );

        jPanel8.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "INGRESE ROL SII", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Century Gothic", 1, 10), java.awt.Color.blue)); // NOI18N

        btnBuscarRolImprimir.setText("BUSCAR");
        btnBuscarRolImprimir.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBuscarRolImprimirActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel8Layout = new javax.swing.GroupLayout(jPanel8);
        jPanel8.setLayout(jPanel8Layout);
        jPanel8Layout.setHorizontalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel8Layout.createSequentialGroup()
                .addGap(34, 34, 34)
                .addGroup(jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                    .addComponent(txtBuscarRolImprimir)
                    .addComponent(btnBuscarRolImprimir, javax.swing.GroupLayout.DEFAULT_SIZE, 122, Short.MAX_VALUE))
                .addContainerGap(29, Short.MAX_VALUE))
        );
        jPanel8Layout.setVerticalGroup(
            jPanel8Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel8Layout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(txtBuscarRolImprimir, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(btnBuscarRolImprimir))
        );

        btnImprimirRol.setText("IMPRIMIR");
        btnImprimirRol.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnImprimirRolActionPerformed(evt);
            }
        });

        btnMenuPrincipalHipo.setText("MENÚ PRINCIPAL");
        btnMenuPrincipalHipo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnMenuPrincipalHipoActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout jPanel6Layout = new javax.swing.GroupLayout(jPanel6);
        jPanel6.setLayout(jPanel6Layout);
        jPanel6Layout.setHorizontalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel7, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addGap(332, 332, 332)
                .addComponent(btnImprimirRol, javax.swing.GroupLayout.PREFERRED_SIZE, 108, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 170, Short.MAX_VALUE)
                .addComponent(btnMenuPrincipalHipo, javax.swing.GroupLayout.PREFERRED_SIZE, 156, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(29, 29, 29))
            .addGroup(jPanel6Layout.createSequentialGroup()
                .addGap(281, 281, 281)
                .addComponent(jPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel6Layout.setVerticalGroup(
            jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanel6Layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jPanel8, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jPanel7, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 35, Short.MAX_VALUE)
                .addGroup(jPanel6Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(btnImprimirRol)
                    .addComponent(btnMenuPrincipalHipo))
                .addContainerGap())
        );

        jTabbedPane1.addTab("IMPRIMIR", jPanel6);

        jLabel3.setText("MENÚ PRINCIPAL\\ELIMINACIÓN GARANTÍA HIPOTECARIA");

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel2)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 72, Short.MAX_VALUE)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel1)
                    .addComponent(jLabel3))
                .addGap(258, 258, 258))
            .addComponent(jTabbedPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(jLabel1)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel3))
                    .addComponent(jLabel2))
                .addGap(18, 18, 18)
                .addComponent(jTabbedPane1)
                .addContainerGap())
        );

        setSize(new java.awt.Dimension(816, 672));
        setLocationRelativeTo(null);
    }// </editor-fold>//GEN-END:initComponents

    private void btnExaminarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnExaminarActionPerformed
      String archivo = garantia.getAdjuntar_hipo();
           if(!archivo.equals("")){  
         File file = new File(archivo);
        try {
            Desktop.getDesktop().open(file);
        } catch (IOException ex) {
            javax.swing.JOptionPane.showMessageDialog(this, "Problema al abrir archivo");
        }
           }else{
           javax.swing.JOptionPane.showMessageDialog(this, "No tiene archivo adjunto");
           }   
    }//GEN-LAST:event_btnExaminarActionPerformed

    private void btnVolverMenuPrincipalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnVolverMenuPrincipalActionPerformed
        MenuPrincipal venMenuPrincipal = new MenuPrincipal(user);
        venMenuPrincipal.setVisible(true);
        EliminacionGarantiaHipotecaria.this.dispose();
    }//GEN-LAST:event_btnVolverMenuPrincipalActionPerformed

    private void btnBuscarPorFolioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarPorFolioActionPerformed
        try
        {
            garantia = reg.buscarPorFolioHipo(Integer.parseInt(txtNumFolioBuscar.getText().trim()));
            if (garantia.getEstado_hipo().equals("Eliminada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Eliminada");
                    this.btnEliminarGarantiaHipo.setVisible(false);
                    limpiar();
                }
            else
            {
           if (!this.txtNumFolioBuscar.getText().matches("[ 0-9]*")) // expresiones regulares para validar
        {
            javax.swing.JOptionPane.showMessageDialog(this, "Ingrese solo números");
            this.txtNumFolioBuscar.setText("");
            limpiar();
        }
       else{
        if(this.txtNumFolioBuscar.getText().length() > 0)
        {
          garantia = reg.buscarPorFolioHipo(Integer.parseInt(txtNumFolioBuscar.getText().trim()));
        if (garantia.getFolio_garantia_hipo() == 0) {
            javax.swing.JOptionPane.showMessageDialog(null, "Garantia NO EXISTENTE");
            txtNumFolioBuscar.setText("");
            limpiar();
            this.txtRolBuscar.setText("");
            this.btnEliminarGarantiaHipo.setVisible(false);
        }
        else
        {
            if(garantia.getEstado_hipo().equals("Ingresada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Ingresada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                else if(garantia.getEstado_hipo().equals("Aprobada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Aprobada.NO PUEDE SER ELIMINADA");
                    this.btnEliminarGarantiaHipo.setVisible(false);
                    this.jPanelCambiandoEstadoActual.setVisible(false);
                }
                else if(garantia.getEstado_hipo().equals("Rechazada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Rechazada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                else if(garantia.getEstado_hipo().equals("Modificada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Modificada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                
            
            txtRut.setText(garantia.getRut_gara_hipo());
            txtApellMaterno.setText(garantia.getApell_materno_hipo());
            txtApellPaterno.setText(garantia.getApell_paterno_hipo());
            txtNombre.setText(garantia.getNombre_hipo());
            txtDescripcion.setText(garantia.getComent_hipo());
            txtSucursal.setText(garantia.getSucursal_hipo());
            txtCobertura.setText(garantia.getCobertura_hipo());
            txtSuperficie.setText(String.valueOf(garantia.getSuperficie_hipo()));
            txtDireccion.setText(garantia.getDireccion_hipo());
            txtRegistroCbr.setText(garantia.getRegistro_cbr_hipo());
            txtRolSii.setText(garantia.getRol_sii_hipo());
            txtUniSuperficie.setText(garantia.getUni_superficie_hipo());
            txtFechCreacion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_crea_hipo()));
            txtFechUltDebito.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_debito_hipo()));
            txtMoneda.setText(garantia.getMoneda_hipo());
            txtTipoConstruccion.setText(garantia.getTipo_construccion_hipo());
            txtComuna.setText(garantia.getComuna_hipo());
            txtEstadoContribu.setText(garantia.getEstado_constrib_hipo());
            txtLocalidadRegistro.setText(garantia.getLocalidad_reg_hipo());
            txtFechUltTasacion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_tasa_hipo()));
            txtNumero.setText(String.valueOf(garantia.getNum_hipo()));
            txtTipoGarantia.setText(garantia.getTipo_garantia_hipo());
            txtGradoPreferencia.setText(garantia.getGrado_prefere_hipo());
            txtMtsConstruidos.setText(String.valueOf(garantia.getMts_construidos_hipo()));
            txtAñosRepertorio.setText(String.valueOf(garantia.getAnos_repertorio_hipo()));
            txtFojas.setText(String.valueOf(garantia.getA_fojas_hipo()));
            try
            {
            this.txtFechModifi.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_modifi_hipo()));
            }catch(Exception e)
            {
                e.getMessage();
            }
            txtExtincion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_extincion_hipo()));
            txtFechUltReval.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_revaluo_hipo()));
            txtFechUtlCredito.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_credito_hipo()));
            this.txtEstadoActualHipotecaria.setText(garantia.getEstado_hipo());
            this.txtRolBuscar.setText("");

        }
        }
        else
        {
            this.btnEliminarGarantiaHipo.setVisible(false);
            this.txtRolBuscar.setText("");
            limpiar();
            javax.swing.JOptionPane.showMessageDialog(this, "Ingrese Número de Folio");
        }
        }}}
        catch(Exception e)
        {
            e.getMessage();
        }
    }//GEN-LAST:event_btnBuscarPorFolioActionPerformed

    private void btnBuscarPorRolActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarPorRolActionPerformed
        try
        {
            garantia = reg.buscarPorRol(txtRolBuscar.getText().trim());
            if (garantia.getEstado_hipo().equals("Eliminada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Eliminada");
                    this.btnEliminarGarantiaHipo.setVisible(false);
                    limpiar();
                }
            else
            {
        if(this.txtRolBuscar.getText().length() > 0)
        {
        garantia = reg.buscarPorRol(txtRolBuscar.getText().trim());
        if (garantia.getFolio_garantia_hipo() == 0) {
            javax.swing.JOptionPane.showMessageDialog(null, "Garantia NO EXISTENTE");
            txtRolBuscar.setText("");
            limpiar();
            this.txtNumFolioBuscar.setText("");
            this.btnEliminarGarantiaHipo.setVisible(false);
        }
        else
        {
            if(garantia.getEstado_hipo().equals("Ingresada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Ingresada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                else if(garantia.getEstado_hipo().equals("Aprobada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Aprobada.NO PUEDE SER ELIMINADA");
                    this.btnEliminarGarantiaHipo.setVisible(false);
                    this.jPanelCambiandoEstadoActual.setVisible(false);
                }
                else if(garantia.getEstado_hipo().equals("Rechazada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Rechazada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                else if(garantia.getEstado_hipo().equals("Modificada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Modificada");
                    this.btnEliminarGarantiaHipo.setVisible(true);
                }
                
            
            txtRut.setText(garantia.getRut_gara_hipo());
            txtApellMaterno.setText(garantia.getApell_materno_hipo());
            txtApellPaterno.setText(garantia.getApell_paterno_hipo());
            txtNombre.setText(garantia.getNombre_hipo());
            txtDescripcion.setText(garantia.getComent_hipo());
            txtSucursal.setText(garantia.getSucursal_hipo());
            txtCobertura.setText(garantia.getCobertura_hipo());
            txtSuperficie.setText(String.valueOf(garantia.getSuperficie_hipo()));
            txtDireccion.setText(garantia.getDireccion_hipo());
            txtRegistroCbr.setText(garantia.getRegistro_cbr_hipo());
            txtRolSii.setText(garantia.getRol_sii_hipo());
            txtUniSuperficie.setText(garantia.getUni_superficie_hipo());
            txtFechCreacion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_crea_hipo()));
            txtFechUltDebito.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_debito_hipo()));
            txtMoneda.setText(garantia.getMoneda_hipo());
            txtTipoConstruccion.setText(garantia.getTipo_construccion_hipo());
            txtComuna.setText(garantia.getComuna_hipo());
            txtEstadoContribu.setText(garantia.getEstado_constrib_hipo());
            txtLocalidadRegistro.setText(garantia.getLocalidad_reg_hipo());
            txtFechUltTasacion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_tasa_hipo()));
            txtNumero.setText(String.valueOf(garantia.getNum_hipo()));
            txtTipoGarantia.setText(garantia.getTipo_garantia_hipo());
            txtGradoPreferencia.setText(garantia.getGrado_prefere_hipo());
            txtMtsConstruidos.setText(String.valueOf(garantia.getMts_construidos_hipo()));
            txtAñosRepertorio.setText(String.valueOf(garantia.getAnos_repertorio_hipo()));
            txtFojas.setText(String.valueOf(garantia.getA_fojas_hipo()));
            try
            {
            this.txtFechModifi.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_modifi_hipo()));
            }catch(Exception e)
            {
                e.getMessage();
            }
            txtExtincion.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_extincion_hipo()));
            txtFechUltReval.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_revaluo_hipo()));
            txtFechUtlCredito.setText(new SimpleDateFormat("dd-MM-yyyy").format(garantia.getFech_ult_credito_hipo()));
            this.txtEstadoActualHipotecaria.setText(garantia.getEstado_hipo());
            this.txtNumFolioBuscar.setText("");
            
        }
        }
        else
        {
            this.btnEliminarGarantiaHipo.setVisible(false);
            this.txtNumFolioBuscar.setText("");
            limpiar();
            javax.swing.JOptionPane.showMessageDialog(this, "Ingrese Número ROLL SII");
        }
        }}
        catch(Exception e)
        {
            e.getMessage();
        }
    }//GEN-LAST:event_btnBuscarPorRolActionPerformed

    private void chkBuscarPorFolioActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_chkBuscarPorFolioActionPerformed
        if (chkBuscarPorFolio.isSelected()) {
            pnlFolioGarantia.setVisible(true);
            pnlRolGarantia.setVisible(false);
        }
        else
        {
            pnlFolioGarantia.setVisible(false);
        }
    }//GEN-LAST:event_chkBuscarPorFolioActionPerformed

    private void chkBuscarPorRolActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_chkBuscarPorRolActionPerformed
        if (chkBuscarPorRol.isSelected()) {
            pnlRolGarantia.setVisible(true);
            pnlFolioGarantia.setVisible(false);
        }
        else
        {
            pnlRolGarantia.setVisible(false);
        }
    }//GEN-LAST:event_chkBuscarPorRolActionPerformed

    private void btnEliminarGarantiaHipoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnEliminarGarantiaHipoActionPerformed
        int respuesta = javax.swing.JOptionPane.showConfirmDialog(null, "Esta seguro de eliminar esta garantia ?", "Eliminacion", JOptionPane.OK_CANCEL_OPTION);
        if(respuesta == 0)
        {
            garantia = new garantiaHipotecariaDTO();
            garantia.setRol_sii_hipo(this.txtRolSii.getText());
            String cambio = this.txtCambiandoEstadoActualHipotecaria.getText();
            String elim = cambio.replaceFirst(cambio, "Eliminada");
            garantia.setEstado_hipo(elim);
            reg.cambiarEstadoeliminarGarantiaHipoticariaPorROLSII(garantia, user);
            javax.swing.JOptionPane.showMessageDialog(null, "Garantia Hipotecaria Eliminada");
            MenuPrincipal venMenuPrincipal = new MenuPrincipal(user);
            venMenuPrincipal.setVisible(true);
            EliminacionGarantiaHipotecaria.this.dispose();
        }
        
    }//GEN-LAST:event_btnEliminarGarantiaHipoActionPerformed

    private void jButton10ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton10ActionPerformed
        MenuPrincipal venMenuPrincipal = new MenuPrincipal(user);
        venMenuPrincipal.setVisible(true);
        EliminacionGarantiaHipotecaria.this.dispose();
    }//GEN-LAST:event_jButton10ActionPerformed

    private void btnBuscarRolImprimirActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarRolImprimirActionPerformed
         try
        {
            garantia = reg.buscarPorRol(this.txtBuscarRolImprimir.getText().trim());
            if (garantia.getEstado_hipo().equals("Eliminada"))
                {
                    javax.swing.JOptionPane.showMessageDialog(this, "Estado Garantía Eliminada");
            String fechaEliminacion = String.valueOf(Fechas.FechaSistema());
            ArrayList<garantiaHipotecariaDTO> salida = reg.ListarPorRolHipo(this.txtBuscarRolImprimir.getText().trim());
            if(salida.isEmpty())
            {
                 
                 this.txtBuscarRolImprimir.setText(null);
                DefaultTableModel modelo =(DefaultTableModel)this.tbSalidaRolImprmir.getModel();      
                modelo.setNumRows(0);
                javax.swing.JOptionPane.showMessageDialog(this, "No hay garantias registradas!");
               
            }else
            {
            DefaultTableModel modelo =(DefaultTableModel)this.tbSalidaRolImprmir.getModel(); 
          
            modelo.setColumnCount(0);
                if(modelo.getColumnCount() < 1)
                {
                    
                    Object[] arr1 ={"Rut: ","Nombre: ","Calle: ", "Garantía: ", "Número identificatorio Hipotecario: ",
                        "Número de folio: ", "Monto incial: ", "Creación de la garantía: ", "Sucursal:  ",
                        "Cobertura: ","Superficie: ","Dirección (Crédito): ", "Registro CBR: ","Unidad Superficie: ",
                        "Fecha último débito: ","Moneda: ","Tipo construcción: ","Comuna: ","Estado contribución: ",
                        "Localidad Registro: ","Fecha última tasación: ","Tipo garantía: ","Grado preferencía: ",
                        "Metros. construidos: ","Años repertorios: ","A. Fojas: ","Fecha vencimiento: ","Fecha último Revaluo: ",
                        "Fecha último crédito: ","Estado de la garantía: ","Fecha Aprobado/Rechazado: ","Fecha de modificación: ",
                        "Fecha de garantía eliminada: ",
                        "Usuario: "  };
                    modelo.addColumn("Concepto", arr1);
                    
                    for(garantiaHipotecariaDTO x: salida)
                {
                    if(x.getFech_modifi_hipo() == null)
                    {
                        fec = "";
                    }
                    else
                    {
                        fec = new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_modifi_hipo());
                    }
                    Object[] arr2 ={
                        x.getRut_gara_hipo(),
                        x.getNombre_hipo()  + "  " + x.getApell_materno_hipo() + "  " + x.getApell_materno_hipo(),
                        x.getCalle_hipo() + "  " + x.getNum_dire_hipo(),x.getNombre_garantia_hipo(),x.getRol_sii_hipo(),x.getFolio_garantia_hipo(),
                        x.getMonto_inicial(),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_crea_hipo()),
                        x.getSucursal_hipo(),
                        x.getCobertura_hipo(),
                        x.getSuperficie_hipo(),
                        x.getDireccion_hipo()+"  "+x.getNum_hipo(),
                        x.getRegistro_cbr_hipo(),
                        x.getUni_superficie_hipo(),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_ult_debito_hipo()),
                        x.getMoneda_hipo(),
                        x.getTipo_construccion_hipo(),
                        x.getComuna_hipo(),
                        x.getEstado_constrib_hipo(),
                        x.getLocalidad_reg_hipo(),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_ult_tasa_hipo()),
                        x.getTipo_garantia_hipo(),
                        x.getGrado_prefere_hipo(),
                        x.getMts_construidos_hipo(),
                        x.getAnos_repertorio_hipo(),
                        x.getA_fojas_hipo(),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_extincion_hipo()),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_ult_revaluo_hipo()),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_ult_credito_hipo()),
                        x.getEstado_hipo(),
                        new SimpleDateFormat("dd-MM-yyyy").format(x.getFech_crea_hipo()),
                        fec,
                        fechaEliminacion,
                        x.getNombre_usuario()

                    };
                     
                    modelo.addColumn("Contenido",arr2);    
                }
                    
                    Object[] arr3 = {" "," "," "," "," "," "," "," "," "," "
                                    ," "," "," "," "," "," "," "," "," "," "," "
                                    ," "," "," "," "," "," "," "," "," "," "," "," "," "};
                    modelo.addColumn("Observaciones",arr3);
                    
                }
                
                
                
            }
            }else
            {
                javax.swing.JOptionPane.showMessageDialog(this, "Solo Imprime los Estados De Garantías Eliminadas");
                this.txtBuscarRolImprimir.setText(null);
                DefaultTableModel modelo =(DefaultTableModel)this.tbSalidaRolImprmir.getModel();      
                modelo.setNumRows(0);
                modelo.setColumnCount(0);
            }
        }catch(Exception e)
        {
            e.getMessage();
        }
    }//GEN-LAST:event_btnBuscarRolImprimirActionPerformed

    private void btnImprimirRolActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnImprimirRolActionPerformed
         try {
            
        int fila= 0;
  
        List Resultados = new ArrayList();
        ComprobanteGeneralDTO tipo;
        Resultados.clear();
        
        for(fila = 0; fila< tbSalidaRolImprmir.getRowCount(); fila++)
        {
            
           tipo = new ComprobanteGeneralDTO(String.valueOf(tbSalidaRolImprmir.getValueAt(fila, 0)),
                    " " + String.valueOf(tbSalidaRolImprmir.getValueAt(fila, 1)), " " + String.valueOf(tbSalidaRolImprmir.getValueAt(fila, 2))  + "\n");
           Resultados.add(tipo);

        }
        
            String reportSource = "C:\\Users\\SoftGroup\\Documents\\NetBeansProjects\\trunk\\AppGarantias\\build\\classes\\Reporte\\ComprobanteGeneralGarantias.jrxml";

            JasperReport jr = JasperCompileManager.compileReport(reportSource);
            
            
            JFrame reporte = new JFrame();
            reporte.setSize(900, 700);
            reporte.setLocationRelativeTo(null);
            reporte.setTitle("IMPRESIÓN");
            String fechaImpresion = String.valueOf(Fechas.FechaSistema());
            
            Map<String, Object> map = new HashMap<String, Object>();
            
            map.put("Titulo", "Sistema Gestión de Garantías Bancarias");
            map.put("fecha", fechaImpresion);
            map.put("nombreBanco", "Banco xxxxxx");
            map.put("subtitulo", "Comprobante Eliminación Hipotecaria");
            map.put("timbre", "Timbre");
            map.put("fechaUsuario","Fecha");
            map.put("firma","Firma");
            
            
            JRBeanCollectionDataSource coleccion = new JRBeanCollectionDataSource(Resultados);
            JasperPrint jp = JasperFillManager.fillReport(jr, map, coleccion);
            JRViewer jv = new JRViewer(jp);
            reporte.getContentPane().add(jv);
            reporte.setVisible(true);
            
            
            
        } catch (JRException e) {
            e.printStackTrace();
            Logger.getLogger(EliminacionGarantiaHipotecaria.class.getName()).log(Level.SEVERE, null, e);
        }
    }//GEN-LAST:event_btnImprimirRolActionPerformed

    private void btnMenuPrincipalHipoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnMenuPrincipalHipoActionPerformed
         MenuPrincipal venMenuPrincipal = new MenuPrincipal(user);
        venMenuPrincipal.setVisible(true);
        EliminacionGarantiaHipotecaria.this.dispose();
    }//GEN-LAST:event_btnMenuPrincipalHipoActionPerformed

    /**
     * @param args the command line arguments
     */
//    public static void main(String args[]) {
//        /*
//         * Set the Nimbus look and feel
//         */
//        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
//        /*
//         * If Nimbus (introduced in Java SE 6) is not available, stay with the
//         * default look and feel. For details see
//         * http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html
//         */
//        try {
//            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
//                if ("Nimbus".equals(info.getName())) {
//                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
//                    break;
//                }
//            }
//        } catch (ClassNotFoundException ex) {
//            java.util.logging.Logger.getLogger(EliminacionGarantiaHipotecaria.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (InstantiationException ex) {
//            java.util.logging.Logger.getLogger(EliminacionGarantiaHipotecaria.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (IllegalAccessException ex) {
//            java.util.logging.Logger.getLogger(EliminacionGarantiaHipotecaria.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
//            java.util.logging.Logger.getLogger(EliminacionGarantiaHipotecaria.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
//        }
//        //</editor-fold>
//
//        /*
//         * Create and display the form
//         */
//        java.awt.EventQueue.invokeLater(new Runnable() {
//
//            public void run() {
//                new EliminacionGarantiaHipotecaria().setVisible(true);
//            }
//        });
//    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btnBuscarPorFolio;
    private javax.swing.JButton btnBuscarPorRol;
    private javax.swing.JButton btnBuscarRolImprimir;
    private javax.swing.JButton btnEliminarGarantiaHipo;
    private javax.swing.JButton btnExaminar;
    private javax.swing.JButton btnImprimirRol;
    private javax.swing.JButton btnMenuPrincipalHipo;
    private javax.swing.JButton btnVolverMenuPrincipal;
    private javax.swing.ButtonGroup buttonGroup1;
    private javax.swing.JCheckBox chkBuscarPorFolio;
    private javax.swing.JCheckBox chkBuscarPorRol;
    private javax.swing.JButton jButton10;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel20;
    private javax.swing.JLabel jLabel21;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel30;
    private javax.swing.JLabel jLabel31;
    private javax.swing.JLabel jLabel36;
    private javax.swing.JLabel jLabel37;
    private javax.swing.JLabel jLabel39;
    private javax.swing.JLabel jLabel40;
    private javax.swing.JLabel jLabel54;
    private javax.swing.JLabel jLabel55;
    private javax.swing.JLabel jLabel56;
    private javax.swing.JLabel jLabel57;
    private javax.swing.JLabel jLabel58;
    private javax.swing.JLabel jLabel59;
    private javax.swing.JLabel jLabel60;
    private javax.swing.JLabel jLabel61;
    private javax.swing.JLabel jLabel62;
    private javax.swing.JLabel jLabel63;
    private javax.swing.JLabel jLabel64;
    private javax.swing.JLabel jLabel65;
    private javax.swing.JLabel jLabel66;
    private javax.swing.JLabel jLabel67;
    private javax.swing.JLabel jLabel68;
    private javax.swing.JLabel jLabel69;
    private javax.swing.JLabel jLabel70;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JPanel jPanel10;
    private javax.swing.JPanel jPanel11;
    private javax.swing.JPanel jPanel14;
    private javax.swing.JPanel jPanel2;
    private javax.swing.JPanel jPanel3;
    private javax.swing.JPanel jPanel4;
    private javax.swing.JPanel jPanel5;
    private javax.swing.JPanel jPanel6;
    private javax.swing.JPanel jPanel7;
    private javax.swing.JPanel jPanel8;
    private javax.swing.JPanel jPanel9;
    private javax.swing.JPanel jPanelCambiandoEstadoActual;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JTabbedPane jTabbedPane1;
    private javax.swing.JLabel lblArchivo;
    private javax.swing.JLabel lblDescripcion;
    private javax.swing.JPanel pnlCreacionGaraHipo;
    private javax.swing.JPanel pnlDatosPersoGara;
    private javax.swing.JPanel pnlDescripGarantia;
    private javax.swing.JPanel pnlFolioGarantia;
    private javax.swing.JPanel pnlRolGarantia;
    private javax.swing.JTable tbSalidaRolImprmir;
    private javax.swing.JTextField txtApellMaterno;
    private javax.swing.JTextField txtApellPaterno;
    private javax.swing.JTextField txtAñosRepertorio;
    private javax.swing.JTextField txtBuscarRolImprimir;
    private javax.swing.JTextField txtCambiandoEstadoActualHipotecaria;
    private javax.swing.JTextField txtCobertura;
    private javax.swing.JTextField txtComuna;
    private javax.swing.JTextArea txtDescripcion;
    private javax.swing.JTextField txtDireccion;
    private javax.swing.JTextField txtEstadoActualHipotecaria;
    private javax.swing.JTextField txtEstadoContribu;
    private javax.swing.JTextField txtExtincion;
    private javax.swing.JTextField txtFechCreacion;
    private javax.swing.JTextField txtFechModifi;
    private javax.swing.JTextField txtFechUltDebito;
    private javax.swing.JTextField txtFechUltReval;
    private javax.swing.JTextField txtFechUltTasacion;
    private javax.swing.JTextField txtFechUtlCredito;
    private javax.swing.JTextField txtFojas;
    private javax.swing.JTextField txtGradoPreferencia;
    private javax.swing.JTextField txtLocalidadRegistro;
    private javax.swing.JTextField txtMoneda;
    private javax.swing.JTextField txtMtsConstruidos;
    private javax.swing.JTextField txtNombre;
    private javax.swing.JTextField txtNumFolioBuscar;
    private javax.swing.JTextField txtNumero;
    private javax.swing.JTextField txtRegistroCbr;
    private javax.swing.JTextField txtRolBuscar;
    private javax.swing.JTextField txtRolSii;
    private javax.swing.JTextField txtRut;
    private javax.swing.JTextField txtSucursal;
    private javax.swing.JTextField txtSuperficie;
    private javax.swing.JTextField txtTipoConstruccion;
    private javax.swing.JTextField txtTipoGarantia;
    private javax.swing.JTextField txtUniSuperficie;
    // End of variables declaration//GEN-END:variables

    private void limpiar() {
            txtRut.setText(null);
            txtApellMaterno.setText(null);
            txtApellPaterno.setText(null);
            txtNombre.setText(null);
            txtDescripcion.setText(null);
            txtSucursal.setText(null);
            txtCobertura.setText(null);
            txtSuperficie.setText(null);
            txtDireccion.setText(null);
            txtRegistroCbr.setText(null);
            txtRolSii.setText(null);
            txtUniSuperficie.setText(null);
            txtFechCreacion.setText(null);
            txtFechUltDebito.setText(null);
            txtMoneda.setText(null);
            txtTipoConstruccion.setText(null);
            txtComuna.setText(null);
            txtEstadoContribu.setText(null);
            txtLocalidadRegistro.setText(null);
            txtFechModifi.setText(null);
            txtFechUltTasacion.setText(null);
            txtNumero.setText(null);
            txtTipoGarantia.setText(null);
            txtGradoPreferencia.setText(null);
            txtMtsConstruidos.setText(null);
            txtAñosRepertorio.setText(null);
            txtFojas.setText(null);
            txtExtincion.setText(null);
            txtFechUltReval.setText(null);
            txtFechUtlCredito.setText(null);
            this.txtEstadoActualHipotecaria.setText(null);
            
    }
}
